﻿using System;
using System.ComponentModel;

namespace eCashDatalayer
{
    public class AllergyModel: INotifyPropertyChanged
    {

        public event PropertyChangedEventHandler PropertyChanged;

        private int _iAllergyID;
        private string _sAllergyName;

        /// When the Property is changed from the PL this gets Fired
        /// </summary>
        /// <param name="property"></param>
        private void OnPropertyChanged(String property)
        {


            if (PropertyChanged != null)
            {
                PropertyChanged(this, new PropertyChangedEventArgs(property));
            }
        }


        public int iAllergyID
        {

            get
            {
                return _iAllergyID;
            }
            set
            {
                _iAllergyID = value;

                OnPropertyChanged("iAllergyID");

            }
        }

        public string sAllergyName
        {

            get
            {
                return _sAllergyName;
            }
            set
            {
                _sAllergyName = value;

                OnPropertyChanged("sAllergyName");

            }
        }
    }
}